import React from 'react';
import User from './User';

const UserResults = ({results }) => {
  if (!results || results.length === 0) {
    return <p>未找到用户数据。</p>;
  }
  return (
    <div>
      <ul>
       {results.map((user, index) => (
          <div key={index}>
            <User user={user} /> {/* 在这里渲染每个帖子的内容 */}
          </div>
        ))}
      </ul>
    </div>
  );
};

export default UserResults;
